<?php

namespace App\Http\Controllers\Admin;

use App\Home\Article;
use Illuminate\Http\Request;
use App\Http\Controllers\Controller;
use Illuminate\Support\Facades\DB;

class Artcontroller extends Controller
{
    //显示文章列表
    public function articleshow(){
        $result = Article::join('users','users.id','=','articles.user_id')->select('articles.*','users.username')->paginate(2);
        return view('admin.article.articlelist',['result'=>$result]);
    }
}
